<%@page import="com.css.core.configuration.Environment"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@ taglib prefix="ww" uri="webwork" %>

    	<div class="header navbar navbar-inverse navbar-fixed-top">
			<div class="navbar-inner">
				<div class="container-fluid">
					<a class="brand" href="explorer.jsp"><%--<img src="custom/metro/brand.png" />--%>领导班子考评系统</a>
					<ul class="nav pull-right">
						<!--<li class="top_sch"><input type="text" id="tabkey"><i class="top_sch_icon" onclick="tabSearch();"></i></li>
						--><li class="dropdown">
						   <ww:if test="#session.sUser.loginName == 'devadmin'">
							<a class="user" title="清空缓存" href="javascript:clearCache();">
							<!-- <i class="icon-setting"></i> -->清空缓存
							</a>
							</ww:if>
						</li>
						<li class="dropdown user">
							<ww:property value="#session.sUser.realName" />
						</li><!--
						
						<li class="dropdown">
							<a class="dropdown" title="主题" href="javascript:showTheme();">
							 <i class="icon-setting"></i> 主题
							</a>
						</li>
						--><li class="dropdown">
							<a class="user" title="设置" href="javascript:showSetting();">
							<!-- <i class="icon-setting"></i> -->设置
							</a>
						</li>
						<li class="dropdown">
							<a class="user" title="退出" href="javascript:quit();">
							<!-- <i class="icon-quit"></i> -->退出
							</a>
						</li>
					</ul>
				</div>
			</div>
		</div>
    	<div class="page-container">
				<div class="page-sidebar" role="main" style="overflow: auto;">
	<!--  			<div class="folder"><a></a></div>-->	
					<ul class="page-sidebar-menu">
						<li class="start active ">
							<a href="firstpage.jsp" rel="home" id="fpTab" target="cssTab" title="首页" refresh="true">
							<i class="icon_home"></i> 
							<span class="title">首&nbsp;&nbsp;&nbsp;&nbsp;页</span>
							<span class="selected"></span>
							</a>
						</li>
					    <li style="display:none;">
							<a href="getIndex.action?portalType=2"  rel="customizeportal"  target="cssTab" title="首页门户" refresh="true">
							<i class="icon_home"></i> 
							<span class="title">首&nbsp;页&nbsp;门&nbsp;户</span>
							<span class="selected"></span>
							</a>
						</li>
						 <ww:property value="@com.css.apps.base.common.util.MenuUtil@getUserMenuContent()"/>
					</ul>
      			</div>
				<div class="page-content">
					<div id="tab-01">
						<ul class="dropdown-menu" id="menu1">
							<li>
								<a href="javascript:;" rel="reload">刷新标签页</a>
							</li>
							<li>
								<a href="javascript:;" rel="close">关闭标签页</a>
							</li>
							<li>
								<a href="javascript:;" rel="closeOther">关闭其他标签页</a>
							</li>
							<li>
								<a href="javascript:;" rel="closeAll">关闭全部标签页</a>
							</li>
						</ul>
						<ul class="nav nav-tabs" context-menu="menu1" style="margin-right:48px">
							<li class="active ">
								<a ptabid="home" tabid="home" href="#home" data-href="firstpage.jsp" style="text-align:center">首&nbsp;&nbsp;&nbsp;&nbsp;页</a>
							</li>
						</ul>
						<div class="tab-btn">
							<a href="javascript:;" data-toggle="dropdown" class="dropdown-toggle more"><i></i></a>
							<ul class="dropdown-menu">
							</ul>
						</div>
						<div class="tab-content layoutBox">
							<div class="tab-pane active" id="home">
									<div style="">
										<ww:include page="firstpage.jsp"/>
									</div>
							</div>
						</div>
					</div>
				</div>
    		</div>

    <script type="text/javascript">
    /* $('.page-sidebar').resizable({handles:'e',onResize:function(){
    }}); */
    g_user={id:'<ww:property value="#session.sUser.userId" />',name:'<ww:property value="#session.sUser.realName" />',loginName:'<ww:property value="#session.sUser.loginName" />'};
    function showSetting() {
    	//$("#settingLi").children().eq(0).click();
    	$navTab.openTab({
            id:'F_0169',
            title:'设置',
            url:'getUserSettings.action',
            active:true
        });
    }                                            
    function showDevice() {
    	$navTab.openTab({
    		id:'SBGL',
            title:'设备管理',
            url:'dirPersonalDev.action',
            active:true
        });
    }
    function showTheme(){
    	$css.openDialog({
    		title:"选择主题风格",
    		url:"getThemeChange.action",
    		lock:false
    	});
    }
    function clearCache() {
    	$.post("clearCache.action", {}, function(data) {
        	$css.tip(data.msg);
        },"json");
    }
    /*$(function() {
		$css.post('firstPage.action',function(data){
			$("#home").html(data);
			$('[href="#home"]').data("loaded",1);
		},'json');
    });*/
    $(function(){
		$('#tabkey').bind('keydown',function(e){
			if(e.keyCode == 13){
				tabSearch();
			}
		});
    });
    var $t = $('[rel="RZGL-TJTB"]');
    if($t[0]){
        $t.attr('iframe','true');
    }
    jQuery(document).ready(function() {
        $('body').off();
        $('body').on('click','[target=cssDialog]',function(){
    	    return $css.openDialog($(this));
        });
        $('body').on('click','[target=closeTab]',function(){
        	return $navTab.closeCurrentTab();
        });
        $('body').on('click','[target=closeDialog]',function(){
        	return $css.closeDialog();
        });
     	handleSidebarMenu();
    	handleSidebarToggler();
       
      var home={};
    	home.id='home';
    	home.title='首&nbsp;&nbsp;&nbsp;&nbsp;页';
    	home.url='firstpage.jsp';
    	$navTab.init('#tab-01',home);
    	$navTab.event();
    	$newTable.event();

    	setTimeout(function(){
    		initLayout();
    	},0);
    	$(window).resize(function(){
    		initLayout();
    	});
    });
    </script>